package com.heima.controller;

import com.heima.domain.vo.BusinessVo;
import com.heima.service.BusinessService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/api/vm-service/businessType")
@Api(tags = "商圈管理")
public class BusinessController {

    @Autowired
    private BusinessService businessService;

    @GetMapping
    @ApiOperation("查询商圈列表")
    public List<BusinessVo> findAll(){
        List<BusinessVo> list = businessService.findAll();
        return list;
    }
}
